# Contributor: Bart Ribbers <bribbers@disroot.org>
# Maintainer: Bart Ribbers <bribbers@disroot.org>
pkgname=poxml
pkgver=20.04.3
pkgrel=0
arch="all !armhf"
url="https://www.kde.org/applications/development/"
pkgdesc="Translates DocBook XML files using gettext po files"
license="GPL-2.0-or-later AND GFDL-1.2-only"
makedepends="extra-cmake-modules qt5-qtbase-dev kdoctools-dev gettext-dev"
source="https://download.kde.org/stable/release-service/$pkgver/src/poxml-$pkgver.tar.xz"
subpackages="$pkgname-doc"

build() {
	cmake -B build \
		-DCMAKE_BUILD_TYPE=None \
		-DCMAKE_INSTALL_PREFIX=/usr \
		-DCMAKE_INSTALL_LIBDIR=lib
	cmake --build build
}

check() {
	cd build
	CTEST_OUTPUT_ON_FAILURE=TRUE ctest
}

package() {
	DESTDIR="$pkgdir" cmake --build build --target install
}

sha512sums="cd258bb659a8ac110d88971c103ad9cd8bec01494c48d06b5717ee05f50482ae86da284b0c5c88d6a4bbbbfbc8a0b1699fe31c5e5ae5cdb0acb3e738e1967d3e  poxml-20.04.3.tar.xz"
